import apiClient from './index';

const categoryService = {
  // 获取分类列表
  getCategories: (params) => {
    // params 可以包含: parent_id, search
    return apiClient.get('/categories', { params });
  },

  // 获取单个分类详情
  getCategory: (idOrSlug) => {
    return apiClient.get(`/categories/${idOrSlug}`);
  },
};

export default categoryService; 